<!DOCTYPE html>
<html>
<head>
<style>
.grid-container {
  display: grid;
  grid-template-columns: 100px 50px auto auto auto auto 100px;
  grid-gap: 10px;
  background-color: #2196F3;
  padding: 10px;
}

 
.grid-container > div {
  background-color: rgba(255, 255, 255, 0.8);
  text-align: center;
  padding: 20px 0;
  font-size: 30px;
} 

#header {
    /* grid-row: 1 / span 2; */
    /* grid-column: 1 / span 7; */
    grid-column: 1 / 8;
    background-color: red;
}
#footer {
    /* grid-row: 1 / span 2; */
    /* grid-column: 1 / span 7; */
    grid-column: 3 / 8;
    background-color: blue;
}
#left{
    /* grid-row: 2/span 10; */
    grid-row: 2/ 13;
    /* grid-column: 1 /span  2; */
    grid-column: 1 /  3;
}
#main{
    /* grid-row: 2/span 10; */
    grid-row: 2/ 12;
    /* grid-column: 3 /span  4; */
    grid-column: 3 /  7;
}
#right{
    /* grid-row: 2/span 10; */
    grid-row: 2/ 12;
    /* grid-column: 3 /span  4; */
    grid-column: 7 /  8;
}
</style>
</head>
<body>

<h1>grid-column 属性：</h1>

<p>请使用 <em>grid-column</em> 属性规定在何处放置项目。</p>

<p>Item1 将在 column 1 开始，并在 column 5 之间结束：</p>

<div class="grid-container">
  <div id="header">header</div>
  <div id="left">left</div>
  <div id="main">main</div>  
  <div id="right">right</div>  
  <div id="footer">footer</div>
</div>

</body>
</html>
